﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="SelectPage.aspx.cs" Inherits="WebSiteApplication.SelectPage" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>选择框</title>
    <link href="Styles/bui.css" rel="stylesheet"/>
    <link href="Styles/dpl.css" rel="stylesheet"/>
</head>
<body>
    <form id="form1" runat="server">
    <div class="demo-content">
        <h2>
            换行</h2>
        <div id="s1">
            <input type="hidden" id="hide" value="汉史" name="hide">
        </div>
        <h2>
            在一行中</h2>
        <div id="s2">
            <input type="hidden" id="hide1" value="近代文学;报告文学" name="hide1"/>
        </div>
        <script type="text/javascript" src="Scripts/jquery-1.8.1.min.js"></script>
        <script type="text/javascript" src="Scripts/sea.js"></script>
        <script type="text/javascript" src="Scripts/config.js"></script>
        <!-- script start -->
        <script type="text/javascript">
            BUI.use('bui/select', function (Select) {

                var items = [
          '辽史', '汉史', '明史', '宋史', '上古史', '夏史', '商史', '周史', '战国史', '晋史', '梁史', '清史'
        ],
        select = new Select.Combox({
            render: '#s1',
            showTag: true,
            width: 500,
            valueField: '#hide', //显示tag的Combox必须存在valueField
            items: items
        });
                select.render();

                var items1 = [
          '古典文学', '近代文学', '当代文学', '报告文学'
        ],
        select1 = new Select.Combox({
            render: '#s2',
            showTag: true,
            width: 500,
            elCls: 'bui-tag-follow',
            valueField: '#hide1', //显示tag的Combox必须存在valueField
            items: items1
        });
                select1.render();


            });
   
        </script>
        <!-- script end -->
    </div>
    </form>
</body>
</html>
